package com.balabala.gym_system.pojo.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * Author:zl
 * Date:2023/5/1 13:05
 */

@Data
@ApiModel("登录dto")
public class LoginDto implements Serializable {


    @ApiModelProperty("用户名")
    @Pattern(regexp = "^\\w{4,18}$",message = "用户名不合法!")
    private String username;


    @ApiModelProperty("密码")
    @Pattern(regexp = "^\\w{6,18}$",message = "密码不合法!")
    private String password;

}